package com.example.AIstudy.service.impl;

import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.example.AIstudy.dao.FalseReasonDao;
import com.example.AIstudy.domain.FalseReason;
import com.example.AIstudy.service.FalseReasonService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class FalseReasonServiceImpl extends ServiceImpl<FalseReasonDao,FalseReason> implements FalseReasonService {

    @Autowired
    FalseReasonDao falseReasonDao;

    //根据用户ID获取到用户的全部错误原因列表
    @Override
    public List<FalseReason> findReasonByUserID(Integer userID) {
        return falseReasonDao.findReasonByUserID(userID);
    }

    public void insertReason(FalseReason falseReason){falseReasonDao.insertReason(falseReason);}
}
